<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2017/11/28
 * Time: 15:22
 */

namespace app\models;

use yii;
use yii\db\Query;

class OperationLog
{
    private $table;

    public function __construct()
    {
        $this->table = yii::$app->db->tablePrefix.'operation_log';
    }

    /**
     * 添加一条记录
     */
    public function insert($array)
    {
        yii::$app->db->createCommand()->insert($this->table,$array)->execute();
    }

}